Method for managing hardware resource, method for querying location of hardware resource, and related apparatus

ABSTRACT

The present embodiments provide a method for managing a hardware resource, a method for querying a location of a hardware resource, and a related apparatus. The method for managing a hardware resource includes receiving, by a virtualized infrastructure manager (VIM), a hardware resource allocation request message sent by a VNF management entity, where the hardware resource allocation request message is used to request the VIM to allocate a hardware resource to a virtual machine that runs a VNFC, and the hardware resource allocation request message includes location information of the hardware resource that the virtual machine requests to allocate. The method also includes allocating, by the VIM, the hardware resource at a corresponding location to the virtual machine according to the location information of the hardware resource.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of U.S. patent application Ser. No.15/587,454, filed on May 5, 2017, which is a continuation ofInternational Patent Application No. PCT/CN2014/090630, filed on Nov. 7,2014. All of the afore-mentioned patent applications are herebyincorporated by reference in their entireties.

TECHNICAL FIELD

Embodiments of the present invention relate to the field ofcommunications technologies, and in particular, to a method for managinga hardware resource, a method for querying a location of a hardwareresource, and a related apparatus.

BACKGROUND

As ideas and technologies such as cloud computing and virtualizationmature, an architecture transformation in the field of a traditionaltelecommunications network is coming. Closeness is replaced by openness,exclusiveness is replaced by generality, and an originally professionalnetwork function that is on a communications network element isextracted and virtualized, and then runs on a general hardware platform;this change is referred to as network functions virtualization (NFV).

An objective of NFV is expecting to implement flexible loading ofsoftware, and flexible configuration of the software at locations suchas a data center, a wide area network, and a campus network by usingstandard hardware to bear various network software functions,exponentially accelerate a speed of network deployment and adjustment,reduce complexity and overall investment cost that are of servicedeployment, and improve unification, generalization, and adaptation thatare of a network device. For a communications network, softwarefunctions of some original standard network elements, such as a gatewaygeneral packet radio service (GPRS) support node (GGSN), a mobilitymanagement entity (MME), and other devices, are virtualized and borne ona general hardware device of a data center.

Lawful interception refers to that: On the premise that no impact iscaused on network element security and all services of a mobilecommunications system, real-time tracing is implemented for all trafficand non-traffic activities of a controlled number, where types ofcontrolled numbers include a Mobile Subscriber International IntegratedServices Digital Network/Public Switched Telephone Network number(MSISDN), an International Mobile Subscriber Identification Number(IMSI), and an International Mobile Equipment Identity (IMEI).

In the prior art, for virtualization of a network element function, in aprocess of performing instantiation on a virtualized network function(VNF), an instantiation template and a parameter related to hardwareinformation generally include only hardware resource information such asa quantity of Central Processing Units (CPU), a memory size, and a harddisk capacity.

For an ordinary service, the service can normally run as long as a CPU,a memory size, a hard disk size, and the like that are required by theservice are provided. However, for a sensitive service such as lawfulinterception, because of a requirement for confidentiality, according tolaws and regulations, a related physical device, and in particular, astorage device that stores information related to lawful interception isgenerally sealed, or another confidentiality measure is taken toprohibit an unauthorized person from touching and operating the relatedphysical device. In addition, after the service is migrated orterminated, a hard disk may need to be destructed according to therequirement for confidentiality. In this case, knowing information suchas a CPU, a memory size, a disk size that are required by the servicecannot meet a requirement. Therefore, it is necessary to provide a newmethod to resolve the foregoing problem.

SUMMARY

In view of this, embodiments of the present invention provide a methodfor managing a hardware resource, a method for querying a location of ahardware resource, and a related apparatus, which can meet a requirementof a sensitive service.

According to a first aspect, a method for managing a hardware resourceprovided in an embodiment of the present invention includes: receiving,by a virtualized infrastructure manager (VIM), a hardware resourceallocation request message sent by a virtualized network function (VNF)management entity, where the hardware resource allocation requestmessage is used to request the VIM to allocate a hardware resource to avirtual machine that runs a virtualized network function component(VNFC), and the hardware resource allocation request message includeslocation information of the hardware resource that the virtual machinerequests to allocate; and allocating, by the VIM, the hardware resourceat a corresponding location to the virtual machine according to thelocation information of the hardware resource.

With reference to the first aspect, in a first implementation manner ofthe first aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

With reference to the first aspect or the first implementation manner ofthe first aspect, in a second implementation manner of the first aspect,the hardware resource allocation request message further includes anexclusive identity or a shared identity, the exclusive identity is usedto identify that the hardware resource, at the specified location, thatthe virtual machine requests to allocate is exclusively occupied by thevirtual machine, and the shared identity is used to identify that thehardware resource, at the specified location, that the virtual machinerequests to allocate may be shared with another virtual machine.

With reference to the second implementation manner of the first aspect,in a third implementation manner of the first aspect, 1 is used toindicate the exclusive identity, and 0 is used to indicate the sharedidentity; or

0 is used to indicate the exclusive identity, and 1 is used to indicatethe shared identity.

With reference to the first aspect, or the first implementation mannerof the first aspect, or the second implementation manner of the firstaspect, or the third implementation manner of the first aspect, in afourth implementation manner of the first aspect, the method furtherincludes: receiving, by the VIM, a hardware resource adjustment requestmessage sent by the VNF management entity, where the hardware resourceadjustment request message includes location information and adjustmentinformation that are of a hardware resource that the VNFC requests toadjust; and adjusting, by the VIM, the hardware resource at acorresponding location according to the hardware resource adjustmentrequest message.

With reference to the first aspect, or the first implementation mannerof the first aspect, or the second implementation manner of the firstaspect, or the third implementation manner of the first aspect, or thefourth implementation manner of the first aspect, in a fifthimplementation manner of the first aspect, the VNF management entityincludes a virtualized network function manager VNFM or a networkfunctions virtualization orchestrator (NFVO).

According to a second aspect, a method for managing a hardware resourceprovided in an embodiment of the present invention includes: acquiring,by a VNF management entity, an instantiated VNF message, where theinstantiated VNF message includes location information of a hardwareresource that a virtual machine running a VNFC requests to allocate; andsending, by the VNF management entity, a hardware resource allocationrequest message to a VIM according to the instantiated VNF message,where the hardware resource allocation request message is used torequest the VIM to allocate the hardware resource to the virtualmachine, and the hardware resource allocation request message includesthe location information of the hardware resource that the virtualmachine requests to allocate.

With reference to the second aspect, in a first implementation manner ofthe second aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

With reference to the second aspect or the first implementation mannerof the second aspect, in a second implementation manner of the secondaspect, the VNF management entity includes a virtualized networkfunction manager VNFM; and the acquiring, by a VNF management entity,the instantiated VNF message includes: receiving, by the VNFM, theinstantiated VNF message sent by an operator or element management (EM).

With reference to the second aspect or the first implementation mannerof the second aspect, in a third implementation manner of the secondaspect, the VNF management entity includes a NFVO; and the acquiring, bya VNF management entity, the instantiated VNF message includes:receiving, by the NFVO, the instantiated VNF message sent by an operatoror an operation support system (OSS).

With reference to the second aspect, or the first implementation mannerof the second aspect, or the second implementation manner of the secondaspect, or the third implementation manner of the second aspect, in afourth implementation manner of the second aspect, the sending, by theVNF management entity, a hardware resource allocation request message tothe VIM according to the instantiated VNF message includes: determining,by the VNF management entity according to the location information ofthe hardware resource, a VIM that manages the hardware resource; andsending, by the VNF management entity, the hardware resource allocationrequest message to the VIM that manages the hardware resource.

With reference to the second aspect, or the first implementation mannerof the second aspect, or the second implementation manner of the secondaspect, or the third implementation manner of the second aspect, or thefourth implementation manner of the second aspect, in a fifthimplementation manner of the second aspect, the method further includes:receiving, by the VNF management entity, a hardware resource adjustmentrequest message sent by the VNFC, where the hardware resource adjustmentrequest message includes location information and adjustment informationthat are of a hardware resource that the VNFC requests to adjust; andforwarding, by the VNF management entity, the hardware resourceadjustment request message to the VIM, so as to request the VIM toadjust the hardware resource at a corresponding location.

According to a third aspect, a method for querying a location of ahardware resource provided in an embodiment of the present inventionincludes: determining, by a VNF management entity, a VNFC that needs tobe queried; searching for, by the VNF management entity according to amapping relationship, a virtual machine that runs the VNFC that needs tobe queried; sending, by the VNF management entity, a VM query request toa VIM that manages the virtual machine, so as to request the VIM toquery hardware resource information of the virtual machine, where the VMquery request includes a virtual machine identity or virtual containeridentity of the virtual machine; and receiving, by the VNF managemententity, the hardware resource information that is of the virtual machineand returned by the VIM, where the hardware resource informationincludes location information of the hardware resource.

With reference to the third aspect, in a first implementation manner ofthe third aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

With reference to the third aspect or the first implementation manner ofthe third aspect, in a second implementation manner of the third aspect,the determining, by a VNF management entity, a VNFC that needs to bequeried includes: determining, by the VNF management entity according toa query request sent by an external system, the VNFC that needs to bequeried, where the query request includes identity information of theVNFC that needs to be queried; or when the VNF management entityverifies related information of any VNFC, determining, by the VNFmanagement entity, that the VNFC is the VNFC that needs to be queried.

With reference to the second implementation manner of the third aspect,in a third implementation manner of the third aspect, the identityinformation of the VNFC that needs to be queried includes a functionalentity identity of the VNFC, or identity information of a VNF to whichthe VNFC belongs, or a VNFC identity, or identity information of a VNFto which the VNFC belongs and a VNFC identity; the identity informationof the VNF includes a functional entity identity of the VNF, or a VNFidentity.

With reference to the third implementation manner of the third aspect,in a fourth implementation manner of the third aspect, the mappingrelationship includes: a correspondence between a functional entityidentity of each VNFC and the virtual machine identity; or acorrespondence between identity information of a VNF to which each VNFCbelongs and the virtual machine identity; or a correspondence between aVNFC identity of each VNFC and the virtual machine identity; or acorrespondence between identity information of a VNF to which each VNFCbelongs and a VNFC identity, and the virtual machine identity; or acorrespondence between a functional entity identity of each VNFC and thevirtual container identity; or a correspondence between identityinformation of a VNF to which each VNFC belongs and the virtualcontainer identity; or a correspondence between a VNFC identity of eachVNFC and the virtual container identity; or a correspondence betweenidentity information of a VNF to which each VNFC belongs and a VNFCidentity, and the virtual container identity.

With reference to the third aspect, or the first implementation mannerof the third aspect, or the second implementation manner of the thirdaspect, or the third implementation manner of the third aspect, or thefourth implementation manner of the third aspect, in a fifthimplementation manner of the third aspect, the VNF management entityincludes a virtualized network function manager VNFM or a NFVO.

According to a fourth aspect, a method for querying a location of ahardware resource provided in an embodiment of the present inventionincludes: receiving, by a VIM, a VM query request sent by a VNFmanagement entity, where the VM query request includes a virtual machineidentity or virtual container identity of a virtual machine that needsto be queried; querying, by the VIM, hardware resource information ofthe virtual machine according to the VM query request; and sending, bythe VIM, the found hardware resource information of the virtual machineto the VNF management entity, where the hardware resource informationincludes location information of the hardware resource.

With reference to the fourth aspect, in a first implementation manner ofthe fourth aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

According to a fifth aspect, an embodiment of the present inventionprovides a VIM, where the VIM is configured to manage a hardwareresource, and the VIM includes: a receiving unit, configured to receivea hardware resource allocation request message sent by a VNF managemententity, where the hardware resource allocation request message is usedto request the VIM to allocate a hardware resource to a virtual machinethat runs a VNFC, and the hardware resource allocation request messageincludes location information of the hardware resource that the virtualmachine requests to allocate; and a processing unit, configured toallocate the hardware resource at a corresponding location to thevirtual machine according to the location information of the hardwareresource.

With reference to the fifth aspect, in a first implementation manner ofthe fifth aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

With reference to the fifth aspect or the first implementation manner ofthe fifth aspect, in a second implementation manner of the fifth aspect,the hardware resource allocation request message further includes anexclusive identity or a shared identity, the exclusive identity is usedto identify that the hardware resource, at the specified location, thatthe virtual machine requests to allocate is exclusively occupied by thevirtual machine, and the shared identity is used to identify that thehardware resource, at the specified location, that the virtual machinerequests to allocate may be shared with another virtual machine.

With reference to the second implementation manner of the fifth aspect,in a third implementation manner of the fifth aspect, 1 is used toindicate the exclusive identity, and 0 is used to indicate the sharedidentity; or 0 is used to indicate the exclusive identity, and 1 is usedto indicate the shared identity.

With reference to the fifth aspect, or the first implementation mannerof the fifth aspect, or the second implementation manner of the fifthaspect, or the third implementation manner of the fifth aspect, in afourth implementation manner of the fifth aspect, the receiving unit isfurther configured to receive a hardware resource adjustment requestmessage sent by the VNF management entity, where the hardware resourceadjustment request message includes location information and adjustmentinformation that are of a hardware resource that the VNFC requests toadjust; and the processing unit is further configured to adjust thehardware resource at a corresponding location according to the hardwareresource adjustment request message.

With reference to the fifth aspect, or the first implementation mannerof the fifth aspect, or the second implementation manner of the fifthaspect, or the third implementation manner of the fifth aspect, or thefourth implementation manner of the fifth aspect, in a fifthimplementation manner of the fifth aspect, the VNF management entityincludes a virtualized network function manager VNFM or a NFVO.

According to a sixth aspect, an embodiment of the present inventionprovides a VNF management entity, where the VNF management entity isconfigured to manage a hardware resource, and the VNF management entityincludes: a receiving unit, configured to acquire an instantiated VNFmessage, where the instantiated VNF message includes locationinformation of a hardware resource that a virtual machine running a VNFCrequests to allocate; and a sending unit, configured to send a hardwareresource allocation request message to a VIM according to theinstantiated VNF message, where the hardware resource allocation requestmessage is used to request the VIM to allocate the hardware resource tothe virtual machine, and the hardware resource allocation requestmessage includes the location information of the hardware resource thatthe virtual machine requests to allocate.

With reference to the sixth aspect, in a first implementation manner ofthe sixth aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

With reference to the sixth aspect or the first implementation manner ofthe sixth aspect, in a second implementation manner of the sixth aspect,the VNF management entity includes a virtualized network functionmanager VNFM; and the receiving unit is specifically configured toreceive the instantiated VNF message sent by an operator or elementmanagement (EM).

With reference to the sixth aspect or the first implementation manner ofthe sixth aspect, in a third implementation manner of the sixth aspect,the VNF management entity includes a NFVO; and the receiving unit isspecifically configured to receive the instantiated VNF message sent byan operator or an OSS.

With reference to the sixth aspect, or the first implementation mannerof the sixth aspect, or the second implementation manner of the sixthaspect, or the third implementation manner of the sixth aspect, in afourth implementation manner of the sixth aspect, the sending unit isspecifically configured to determine, according to the locationinformation of the hardware resource, a VIM that manages the hardwareresource, and send the hardware resource allocation request message tothe VIM that manages the hardware resource.

With reference to the sixth aspect, or the first implementation mannerof the sixth aspect, or the second implementation manner of the sixthaspect, or the third implementation manner of the sixth aspect, or thefourth implementation manner of the sixth aspect, in a fifthimplementation manner of the sixth aspect, the receiving unit is furtherconfigured to receive a hardware resource adjustment request messagesent by the VNFC, where the hardware resource adjustment request messageincludes location information and adjustment information that are of ahardware resource that the VNFC requests to adjust; and the sending unitis further configured to forward the hardware resource adjustmentrequest message to the VIM, so as to request the VIM to adjust thehardware resource at a corresponding location.

According to a seventh aspect, an embodiment of the present inventionprovides a VNF management entity, where the VNF management entity isconfigured to query a location of a hardware resource, and the VNFmanagement entity includes: a processing unit, configured to determine aVNFC that needs to be queried, and search for, according to a mappingrelationship, a virtual machine that runs the VNFC that needs to bequeried; a sending unit, configured to send a virtual machine (VM) queryrequest to a VIM that manages the virtual machine, so as to request theVIM to query hardware resource information of the virtual machine, wherethe VM query request includes a virtual machine identity or virtualcontainer identity of the virtual machine; and a receiving unit,configured to receive the hardware resource information that is of thevirtual machine and returned by the VIM, where the hardware resourceinformation includes location information of the hardware resource.

With reference to the seventh aspect, in a first implementation mannerof the seventh aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

With reference to the seventh aspect or the first implementation mannerof the seventh aspect, in a second implementation manner of the seventhaspect, the determining, by the processing unit, a VNFC that needs to bequeried includes: determining, by the processing unit according to aquery request sent by an external system, the VNFC that needs to bequeried, where the query request includes identity information of theVNFC that needs to be queried; or when the VNF management entityverifies related information of any VNFC, determining, by the processingunit, that the VNFC is the VNFC that needs to be queried.

With reference to the second implementation manner of the seventhaspect, in a third implementation manner of the seventh aspect, theidentity information of the VNFC that needs to be queried includes afunctional entity identity of the VNFC, or identity information of a VNFto which the VNFC belongs, or a VNFC identity, or identity informationof a VNF to which the VNFC belongs and a VNFC identity; the identityinformation of the VNF includes a functional entity identity of the VNF,or a VNF identity.

With reference to the third implementation manner of the seventh aspect,in a fourth implementation manner of the seventh aspect, the mappingrelationship includes: a correspondence between a functional entityidentity of each VNFC and the virtual machine identity; or acorrespondence between identity information of a VNF to which each VNFCbelongs and the virtual machine identity; or a correspondence between aVNFC identity of each VNFC and the virtual machine identity; or acorrespondence between identity information of a VNF to which each VNFCbelongs and a VNFC identity, and the virtual machine identity; or acorrespondence between a functional entity identity of each VNFC and thevirtual container identity; or a correspondence between identityinformation of a VNF to which each VNFC belongs and the virtualcontainer identity; or a correspondence between a VNFC identity of eachVNFC and the virtual container identity; or a correspondence betweenidentity information of a VNF to which each VNFC belongs and a VNFCidentity, and the virtual container identity.

With reference to the seventh aspect, or the first implementation mannerof the seventh aspect, or the second implementation manner of theseventh aspect, or the third implementation manner of the seventhaspect, or the fourth implementation manner of the seventh aspect, in afifth implementation manner of the seventh aspect, the VNF managemententity includes a virtualized network function manager VNFM or a NFVO.

According to an eighth aspect, an embodiment of the present inventionprovides a VIM, where the VIM is configured to query a location of ahardware resource, and the VIM includes: a receiving unit, configured toreceive a virtual machine (VM) query request sent by a VNF managemententity, where the VM query request includes a virtual machine identityor virtual container identity of a virtual machine that needs to bequeried; a querying unit, configured to query hardware resourceinformation of the virtual machine according to the VM query request;and a sending unit, configured to send the found hardware resourceinformation of the virtual machine to the VNF management entity, wherethe hardware resource information includes location information of thehardware resource.

With reference to the eighth aspect, in a first implementation manner ofthe eighth aspect, the location information of the hardware resourceincludes any one or any combination of the following: city information,equipment room information, cabinet information, a device identity, aport network identity, and a network interface identity.

It can be learned from the foregoing technical solutions that theembodiments of the present invention have the following advantages: Inthe embodiments of the present invention, when a virtual machine needs ahardware resource, a VIM receives a hardware resource allocation requestmessage sent by a VNF management entity, where the hardware resourceallocation request message includes location information of the hardwareresource that the virtual machine requests to allocate; the VIMallocates the hardware resource at a corresponding location to thevirtual machine according to the location information that is of thehardware resource and included in the hardware resource allocationrequest message. That is, in the embodiments of the present invention,location information of a hardware resource that a virtual machinerunning a service requests to allocate may be carried in a hardwareresource allocation request message, and the VIM may allocate a hardwareresource at a specified location to the virtual machine. Therefore, arequirement of a sensitive service can be met.

BRIEF DESCRIPTION OF THE DRAWINGS

To describe the technical solutions in the embodiments of the presentinvention more clearly, the following briefly introduces theaccompanying drawings required for describing the embodiments.Apparently, the accompanying drawings in the following description showmerely some embodiments of the present invention, and a person ofordinary skill in the art may still derive other drawings from theseaccompanying drawings without creative efforts.

FIG. 1 is a schematic diagram of an embodiment of a method for managinga hardware resource according to the present invention;

FIG. 2 is a schematic diagram of another embodiment of a method formanaging a hardware resource according to the present invention;

FIG. 3 is a schematic diagram of another embodiment of a method formanaging a hardware resource according to the present invention;

FIG. 4 is a schematic diagram of another embodiment of a method formanaging a hardware resource according to the present invention;

FIG. 5 is a schematic diagram of an embodiment of a method for queryinga location of a hardware resource according to the present invention;

FIG. 6 is a schematic diagram of another embodiment of a method forquerying a location of a hardware resource according to the presentinvention;

FIG. 7 is a schematic diagram of an embodiment of a virtualizedinfrastructure manager (VIM) according to the present invention;

FIG. 8 is a schematic diagram of an embodiment of a virtualized networkfunction (VNF) management entity according to the present invention;

FIG. 9 is a schematic diagram of another embodiment of a VNF managemententity according to the present invention; and

FIG. 10 is a schematic diagram of another embodiment of a VIM accordingto the present invention.

DETAILED DESCRIPTION OF ILLUSTRATIVE EMBODIMENTS

The following describes the technical solutions in the embodiments ofthe present invention with reference to the accompanying drawings in theembodiments of the present invention. Apparently, the describedembodiments are merely a part rather than all of the embodiments of thepresent invention. All other embodiments obtained by a person ofordinary skill in the art based on the embodiments of the presentinvention without creative efforts shall fall within the protectionscope of the present embodiments.

The present embodiments provide a method for managing a hardwareresource, a method for querying a location of a hardware resource, and arelated apparatus, which can meet a requirement of a sensitive service.

Referring to FIG. 1 , FIG. 1 is an embodiment of a method for managing ahardware resource according to the present embodiments, and the methodin this embodiment includes:

101. A virtualized infrastructure manager (VIM) receives a hardwareresource allocation request message sent by a virtualized networkfunction (VNF) management entity, where the hardware resource allocationrequest message is used to request the VIM to allocate a hardwareresource to a virtual machine, and the hardware resource allocationrequest message includes location information of the hardware resourcethat the virtual machine requests to allocate.

The virtual machine is a virtual machine that runs a virtualized networkfunction component (VNFC). The hardware resource allocation request mayfurther include information such as a quantity of central processingunits (CPUs), and/or a memory size, and/or a hard disk capacity that thevirtual machine requests to allocate.

102. The VIM allocates the hardware resource at a corresponding locationto the virtual machine according to the location information of thehardware resource.

The virtualized infrastructure manager (VIM) may allocate a specifiedresource at a specified location to the virtual machine.

After the VIM completes hardware resource allocation according to arequest of the virtual machine, the VIM may send a hardware resourceallocation acknowledgment message to the VNF management entity, so as toacknowledge that the hardware resource at the specified location hasbeen allocated to the virtual machine.

In this embodiment, a VNF management entity may carry, in a hardwareresource allocation request message, location information of a hardwareresource that a virtual machine running a service requests to allocate;a VIM receives the hardware resource allocation request message, andallocates the hardware resource at a specified location to the virtualmachine according to the hardware resource allocation request message.In this way, for a sensitive service such as lawful interception,location information of a hardware resource related to the sensitiveservice may be clearly known; and according to the location information,sealing of a related physical device may be implemented, aconfidentiality measure is taken to prohibit an unauthorized person fromtouching, operating, and destructing the related physical device, andthe like, thereby meeting a requirement of the sensitive service.

For ease of understanding, the following describes a method for managinga hardware resource in the present embodiments by using a specificembodiment. Referring to FIG. 2 , the method in this embodimentincludes.

201. A VIM receives a hardware resource allocation request message sentby a VNF management entity, where the hardware resource allocationrequest message is used to request the VIM to allocate a hardwareresource to a virtual machine, and the hardware resource allocationrequest message includes location information of the hardware resourcethat the virtual machine requests to allocate.

In specific implementation, the VNF management entity includes avirtualized network function manager (VNFM) or a network functionsvirtualization orchestrator (NFVO).

The virtual machine is a virtual machine that runs a VNFC. In additionto the location information of the hardware resource, the hardwareresource allocation request message may further include information suchas an exclusive identity or a shared identity, and/or a quantity of CPUsand/or a memory size and/or a hard disk capacity that the virtualmachine requests to allocate.

The location information of the hardware resource may be any one or anycombination of the following: city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity; 1 may be used to indicatethe exclusive identity, and 0 may be used to indicate the sharedidentity; and vice versa. The exclusive identity is used to identifythat the hardware resource, at the specified location, that the virtualmachine requests to allocate is exclusively occupied by the virtualmachine, and the shared identity is used to identify that the hardwareresource, at the specified location, that the virtual machine requeststo allocate may be shared with another virtual machine. When a servicethat runs on the virtual machine is a sensitive service, for securityconsideration, the hardware resource allocation request message hadbetter carry the exclusive identity.

202. The VIM allocates the hardware resource at a corresponding locationto the virtual machine according to the location information of thehardware resource.

In specific implementation, the location information of the hardwareresource may be any one or any combination of the following: cityinformation, equipment room information, cabinet information, a deviceidentity, a port network identity, and a network interface identity.That the VIM allocates a hardware resource at a specified location tothe virtual machine may include the following situations: First, only aspecific location of the hardware resource is specified, for example,the location information is information about an equipment room, butresources are not specified, then all resources at the location may beallocated to the virtual machine, and all hardware at the location maybe monitored subsequently; second, a specific hardware device isspecified, for example, the location information is a device identity,but a location at which the hardware device is placed is not limited,and then wherever the hardware device is placed subsequently, thehardware device needs to be monitored; third, a location of the hardwareresource and a specific hardware device are specified, and in this case,a specified device at a specified location may be monitoredsubsequently.

After the VIM completes hardware resource allocation according to therequest of the virtual machine, the VIM may send a hardware resourceallocation acknowledgment message to the VNF management entity, so as toacknowledge that the hardware resource at the specified location hasbeen allocated to the virtual machine.

203. The VIM receives a hardware resource adjustment request messagesent by the VNF management entity, where the hardware resourceadjustment request message includes location information and adjustmentinformation that are of a hardware resource that a VNFC requests toadjust.

In a running process, the VNFC may send the hardware resource adjustmentrequest message to the VNF management entity according to usage of ahardware resource of the VNFC; the VNF management entity forwards thehardware resource adjustment request message to the VIM, so as torequest the VIM to adjust the hardware resource at a correspondinglocation, where adjustment information included in the hardware resourceadjustment request message may be information such as memory or diskexpansion and CPU or memory reduction.

204. The VIM adjusts the hardware resource at the corresponding locationaccording to the hardware resource adjustment request message.

According to the hardware resource adjustment request message, the VIMmay expand a memory or disk at a specified location, and reduce a CPU ormemory at a specified location.

After the VIM completes hardware resource adjustment according to arequest of the VNFC, the VIM may send a hardware resource adjustmentacknowledgment message to the VNF management entity, so as toacknowledge that the hardware resource at the specified location hasbeen adjusted for the VNFC.

In this embodiment, a VNF management entity may carry, in a hardwareresource allocation request message, location information of a hardwareresource that a virtual machine running a service requests to allocate;a VIM receives the hardware resource allocation request message, andallocates the hardware resource at a specified location to the virtualmachine according to the hardware resource allocation request message.In this way, for a sensitive service such as lawful interception,location information of a hardware resource related to the sensitiveservice may be clearly known; and according to the location information,sealing of a related physical device may be implemented, aconfidentiality measure is taken to prohibit an unauthorized person fromtouching, operating, and destructing the related physical device, and soon, thereby meeting a requirement of the sensitive service. In addition,the VIM in this embodiment may further adjust a hardware resource at acorresponding location according to a hardware resource adjustmentrequest message sent by the VNF management entity, so as to further meetrequirements of different services.

The foregoing two embodiments describe, from a perspective of a VIM, themethods for managing a hardware resource provided in the presentembodiments; the following two embodiments describe, from a perspectiveof a VNF management entity, methods for managing a hardware resourceprovided in the present embodiments.

Referring to FIG. 3 , a method for managing a hardware resource in anembodiment includes.

301. A VNF management entity acquires an instantiated VNF message, wherethe instantiated VNF message includes location information of a hardwareresource that a virtual machine requests to allocate.

The virtual machine is a virtual machine that runs a VNFC. Theinstantiated VNF message may further include information such as aquantity of CPUs, and/or a memory size, and/or a hard disk capacity thatthe virtual machine requests to allocate.

302. The VNF management entity sends a hardware resource allocationrequest message to a VIM according to the instantiated VNF message, soas to request the VIM to allocate the hardware resource to the virtualmachine, where the hardware resource allocation request message includesthe location information of the hardware resource that the virtualmachine requests to allocate.

The hardware resource allocation request message may further includeinformation such as a quantity of CPUs, and/or a memory size, and/or ahard disk capacity that the virtual machine requests to allocate.

After the VNF management entity sends a hardware resource allocationrequest to the VIM, the VNF management entity may receive a hardwareresource allocation acknowledgment message sent by the VIM, whichacknowledges that a hardware resource at a specified location has beenallocated to the VM. In this embodiment, after acquiring an instantiatedVNF message, a VNF management entity may carry, in a hardware resourceallocation request message, location information that is of a hardwareresource that a virtual machine running a service requests to allocateand included in the instantiated VNF message, so as to request a VIM toallocate the hardware resource at a specified location to the virtualmachine according to the hardware resource allocation request message.In this way, for a sensitive service such as lawful interception,location information of a hardware resource related to the sensitiveservice may be clearly known; and according to the location information,sealing of a related physical device may be implemented, aconfidentiality measure is taken to prohibit an unauthorized person fromtouching, operating, and destructing the related physical device, and soon, thereby meeting a requirement of the sensitive service.

Referring to FIG. 4 , FIG. 4 is a specific embodiment of a method formanaging a hardware resource according to the present embodiments; themethod in this embodiment includes.

401. A VNF management entity acquires an instantiated VNF message, wherethe instantiated VNF message includes location information of a hardwareresource that a virtual machine requests to allocate.

In specific implementation, the VNF management entity includes avirtualized network function manager VNFM or a NFVO. When the VNFmanagement entity includes the VNFM, that the VNF management entityacquires the instantiated VNF message is specifically receiving, by theVNFM, the instantiated VNF message sent by an operator or elementmanagement (EM). When the VNF management entity includes the NFVO, thatthe VNF management entity acquires the instantiated VNF message isspecifically receiving, by the NFVO, the instantiated VNF message sentby an operator or an operation support system (OSS) (Operation SupportSystem, OSS).

The virtual machine includes a virtual machine that runs a VNFC. Inaddition to the location information of the hardware resource, theinstantiated VNF message may further include information such as anexclusive identity or a shared identity, and/or a quantity of CPUsand/or a memory size and/or a hard disk capacity that the virtualmachine requests to allocate.

The location information of the hardware resource may be any one or anycombination of the following: city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity; 1 may be used to indicatethe exclusive identity, and 0 may be used to indicate the sharedidentity; and vice versa. The exclusive identity is used to identifythat the hardware resource, at a specified location, that the virtualmachine requests to allocate is exclusively occupied by the virtualmachine, and the shared identity is used to identify that the hardwareresource, at the specified location, that the virtual machine requeststo allocate may be shared with another virtual machine. When a servicethat runs on the virtual machine is a sensitive service, for securityconsideration, the instantiated VNF message had better carry theexclusive identity.

402. The VNF management entity sends a hardware resource allocationrequest message to a VIM according to the instantiated VNF message, soas to request the VIM to allocate the hardware resource to the virtualmachine, where the hardware resource allocation request message includesthe location information of the hardware resource that the virtualmachine requests to allocate.

In specific implementation, the VNF management entity first determines,according to the location information that is of the hardware resourceand included in the instantiated VNF message, a VIM that manages thehardware resource, and then sends the hardware resource allocationrequest message to the VIM that manages the hardware resource. Thehardware resource request message may further include other informationincluded in the instantiated VNF message.

In specific implementation, the location information of the hardwareresource may be any one or any combination of the following: cityinformation, equipment room information, cabinet information, a deviceidentity, a port network identity, and a network interface identity.That the VNF management entity requests the VIM to allocate a hardwareresource at a specified location to the virtual machine may include thefollowing situations: First, only a specific location of the hardwareresource is specified, for example, the location information isinformation about an equipment room, but resources are not specified,then all resources at the location may be allocated to the virtualmachine, and all hardware at the location may be monitored subsequently;second, a specific hardware device is specified, for example, thelocation information is a device identity, but a location at which thehardware device is placed is not limited, and then wherever the hardwaredevice is placed subsequently, the hardware device needs to bemonitored; third, a location of the hardware resource and a specifichardware device are specified, and in this case, a specified device at aspecified location may be monitored subsequently.

After the VIM completes hardware resource allocation according to arequest of the virtual machine, the VIM may send a hardware resourceallocation acknowledgment message to the VNF management entity, so as toacknowledge that the hardware resource at the specified location hasbeen allocated to the virtual machine; the VNF management entityreceives the hardware resource allocation acknowledgment message.

403. The VNF management entity receives a hardware resource adjustmentrequest message sent by a VNFC, where the hardware resource adjustmentrequest message includes location information and adjustment informationthat are of a hardware resource that the VNFC requests to adjust.

In a running process, the VNFC may send the hardware resource adjustmentrequest message to the VNF management entity according to usage of ahardware resource of the VNFC; the VNF management entity receives thehardware resource adjustment request message, where adjustmentinformation included in the hardware resource adjustment request messagemay be information such as memory or disk expansion and CPU or memoryreduction.

404. The VNF management entity forwards the hardware resource adjustmentrequest message to the VIM, so as to request the VIM to adjust thehardware resource at a corresponding location.

The VNF management entity may request the VIM to expand a memory or diskat a specified location, and reduce a CPU or memory at a specifiedlocation.

After forwarding the hardware resource adjustment request message to theVIM, the VNF management entity may receive a hardware resourceadjustment acknowledgment message sent by the VIM, which acknowledgesthat adjustment of the location of the hardware resource is successful.

In this embodiment, after acquiring an instantiated VNF message, a VNFmanagement entity may carry, in a hardware resource allocation requestmessage, location information that is of a hardware resource that avirtual machine running a service requests to allocate and included inthe instantiated VNF message, and send the hardware resource allocationrequest message to a VIM, so as to request the VIM to allocate ahardware resource at a specified location to the virtual machineaccording to the hardware resource allocation request message. In thisway, for a sensitive service such as lawful interception, locationinformation of a hardware resource related to the sensitive service maybe clearly known; and according to the location information, sealing ofa related physical device may be implemented, a confidentiality measureis taken to prohibit an unauthorized person from touching, operating,and destructing the related physical device, and so on, thereby meetinga requirement of the sensitive service. In addition, the VNF managemententity in this embodiment may further forward, to the VIM, a hardwareresource adjustment request message sent by a VNF or a VNFC, so as torequest the VIM to adjust a hardware resource at a correspondinglocation, thereby further meeting requirements of different services.

The following introduces a method for querying a location of a hardwareresource provided in the present embodiments; referring to FIG. 5 , themethod in this embodiment includes.

501. A VNF management entity determines a VNFC that needs to be queried.

In specific implementation, the VNF management entity may determine,according to a query request sent by an external system, the VNFC thatneeds to be queried, where the query request includes identityinformation of the VNFC that needs to be queried. The external systemmay be a management system of a sensitive service.

The identity information of the VNFC that needs to be queried includes afunctional entity identity of the VNFC (the functional entity identityis information that is used to identify a VNFC and agreed by the VNFmanagement entity and the external system, for example, an IP address ofa VNFC functional entity) (VNFC entity id), or identity information of aVNF to which the VNFC belongs (when the VNF has only one VNFC, theidentity information of the VNF to which the VNFC belongs may be used toidentify the VNFC) (the identity information of the VNF includes afunctional entity identity VNF entity id of the VNF or a VNF identityVNF id), or a VNFC identity (VNFC id), or a combination of identityinformation of a VNF to which the VNFC belongs and a VNFC identity (VNFid+VNFC id or VNF entity id+VNFC id).

In addition, when the VNF management entity needs to verify relatedinformation of any VNFC, for example, to verify whether a location of ahardware resource of a VNFC is valid, the VNF management entitydetermines that the VNFC is the VNFC that needs to be queried.

502. The VNF management entity searches for, according to a mappingrelationship, a virtual machine that runs the VNFC that needs to bequeried.

The mapping relationship includes: a correspondence between a functionalentity identity of each VNFC and the virtual machine identity (VNFCentity id<=>VM id); or a correspondence between identity information ofa VNF to which each VNFC belongs and the virtual machine identity (VNFid<=>VM id or VNF entity id<=>VM id); or a correspondence between a VNFCidentity of each VNFC and the virtual machine identity (VNFC id<=>VMid); or a correspondence between a combination of identity informationof a VNF to which each VNFC belongs and a VNFC identity, and the virtualmachine identity (VNF id+VNFC id<=>VM id or VNF entity id+VNFC id<=>VMid); or a correspondence between a functional entity identity of eachVNFC and the virtual container identity (VNFC entity id<=>VC id); or acorrespondence between identity information of a VNF to which each VNFCbelongs and the virtual container identity (VNF id<=>VC id or VNF entityid<=>VC id); or a correspondence between a VNFC identity of each VNFCand the virtual container identity (VNFC id<=>VC id); or acorrespondence between a combination of identity information of a VNF towhich each VNFC belongs and a VNFC identity, and the virtual containeridentity (VNF id+VNFC id<=>VC id or VNF entity id+VNFC id<=>VC id). Themapping relationship may be dynamically maintained and updated in realtime.

503. The VNF management entity sends a VM query request to a VIM thatmanages the virtual machine, so as to request the VIM to query hardwareresource information of the virtual machine.

The VM query request includes a virtual machine identity (VM id) orvirtual container identity (VC id) of the virtual machine.

504. The VNF management entity receives the hardware resourceinformation that is of the virtual machine and returned by the VIM,where the hardware resource information includes location information ofa hardware resource.

The location information of the hardware resource includes any one orany combination of the following: city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity. In addition, the hardwareresource information that is of the virtual machine and returned by theVIM may further include information such as a quantity of CPUs and/or amemory size that are/is allocated to the virtual machine.

In specific implementation, the foregoing VNF management entity includesa virtualized network function manager VNFM or a NFVO.

In this embodiment, a VNF management entity may search for, according toa mapping relationship, a virtual machine that runs a VNF that needs tobe queried or a virtual machine that runs a VNFC, and then send a VMquery request to a VIM, so as to request the VIM to query hardwareresource information of the virtual machine, where the hardware resourceinformation includes location information of a hardware resource. Inthis way, for a sensitive service such as lawful interception, locationinformation of a hardware resource related to the sensitive service maybe clearly known; and according to the location information, sealing ofa related physical device may be implemented, a confidentiality measureis taken to prohibit an unauthorized person from touching, operating,and destructing the related physical device, and so on, thereby meetinga requirement of the sensitive service.

The foregoing embodiment describes, from a perspective of a VNFmanagement entity, the method for querying a location of a hardwareresource provided in the present embodiments; the following embodimentdescribes, from a perspective of a VIM, a method for querying a locationof a hardware resource provided in the present embodiments.

Referring to FIG. 6 , the method for querying a location of a hardwareresource in this embodiment includes.

601. A VIM receives a virtual machine (VM) query request sent by a VNFmanagement entity, where the VM query request includes a virtual machineidentity or virtual container identity of a virtual machine that needsto be queried.

602. The VIM queries hardware resource information of the virtualmachine according to the VM query request.

603. The VIM sends the found hardware resource information of thevirtual machine to the VNF management entity, where the hardwareresource information includes location information of the hardwareresource.

The location information of the hardware resource includes any one orany combination of the following: city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity.

The hardware resource information that is of the virtual machine andfound by the VIM may further include information such as a quantity ofCPUs and/or a memory size that are/is allocated to the virtual machine.

In this embodiment, after receiving a VM query request sent by a VNFmanagement entity, a VIM may query hardware resource information of avirtual machine that runs a VNF or VNFC that needs to be queried, andthen return found hardware resource information to the VNF managemententity, where the hardware resource information includes locationinformation of a hardware resource. In this way, for a sensitive servicesuch as lawful interception, location information of a hardware resourcerelated to the sensitive service may be clearly known; and according tothe location information, sealing of a related physical device may beimplemented, a confidentiality measure is taken to prohibit anunauthorized person from touching, operating, and destructing therelated physical device, and so on, thereby meeting a requirement of thesensitive service.

The following introduces a virtualized infrastructure manager (VIM) ofthe present embodiments. Referring to FIG. 7 , a VIM 700 in anembodiment is configured to manage a hardware resource, and the VIM 700in this embodiment includes: a receiving unit 701, configured to receivea hardware resource allocation request message sent by a VNF managemententity, where the hardware resource allocation request message is usedto request the VIM to allocate a hardware resource to a virtual machinethat runs a virtualized network function component (VNFC), and thehardware resource allocation request message includes locationinformation of the hardware resource that the virtual machine requeststo allocate; and a processing unit 702, configured to allocate thehardware resource at a corresponding location to the virtual machineaccording to the location information of the hardware resource.

In specific implementation, the VNF management entity includes a VNFM oran NFVO.

When a virtual machine that runs a VNFC requests allocation of ahardware resource, the receiving unit 701 receives a hardware resourceallocation request sent by the VNF management entity. In addition tolocation information of the hardware resource, the hardware resourceallocation request message may further include information such as anexclusive identity or a shared identity, and/or a quantity of CPUsand/or a memory size and/or a hard disk capacity that the virtualmachine requests to allocate.

The location information of the hardware resource may be any one or anycombination of the following: city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity; 1 may be used to indicatethe exclusive identity, and 0 may be used to indicate the sharedidentity; and vice versa. The exclusive identity is used to identifythat the hardware resource, at the specified location, that the virtualmachine requests to allocate is exclusively occupied by the virtualmachine, and the shared identity is used to identify that the hardwareresource, at the specified location, that the virtual machine requeststo allocate may be shared with another virtual machine. When a servicethat runs on the virtual machine is a sensitive service, for securityconsideration, the hardware resource allocation request message hadbetter carry the exclusive identity. The processing unit 702 mayallocate a specified resource at a specified location to the virtualmachine according to the hardware resource allocation request messagereceived by the receiving unit 701.

In a running process, the VNFC may send a hardware resource adjustmentrequest message to the VNF management entity according to usage of ahardware resource of the VNFC; the VNF management entity forwards thehardware resource adjustment request message to the VIM, so as torequest the VIM to adjust the hardware resource at a correspondinglocation; the receiving unit 701 receives the hardware resourceadjustment request message, where the hardware resource adjustmentrequest message includes location information and adjustment informationthat are of a hardware resource that the VNFC requests to adjust, andthe adjustment information includes information such as memory or diskexpansion and CPU or memory reduction.

According to the hardware resource adjustment request message receivedby the receiving unit 701, the processing unit 702 may expand a memoryor disk at a specified location, and reduce a CPU or memory at aspecified location.

In this embodiment, a VNF management entity may carry, in a hardwareresource allocation request message, location information of a hardwareresource that a virtual machine running a service requests to allocate;a receiving unit receives the hardware resource allocation requestmessage; a processing unit allocates a hardware resource at a specifiedlocation to the virtual machine according to the hardware resourceallocation request message. In this way, for a sensitive service such aslawful interception, location information of a hardware resource relatedto the sensitive service may be clearly known; and according to thelocation information, sealing of a related physical device may beimplemented, a confidentiality measure is taken to prohibit anunauthorized person from touching, operating, and destructing therelated physical device, and so on, thereby meeting a requirement of thesensitive service. In addition, the VIM in this embodiment may furtheradjust a hardware resource at a corresponding location according to ahardware resource adjustment request message sent by the VNF managemententity, so as to further meet requirements of different services.

In a specific embodiment, the VIM that is configured to manage ahardware resource may include a transceiver and a processor, where: thetransceiver is configured to receive a hardware resource allocationrequest message sent by a VNF management entity, where the hardwareresource allocation request message is used to request the VIM toallocate a hardware resource to a virtual machine that runs a VNFC, andthe hardware resource allocation request message includes locationinformation of the hardware resource that the virtual machine requeststo allocate; and

the processor is configured to allocate the hardware resource at acorresponding location to the virtual machine according to the locationinformation of the hardware resource received by the transceiver.

It should be noted that the VIM in this embodiment may further beconfigured to implement other functions that can be implemented by theforegoing VIM that is configured to manage a hardware resource, anddetails are not described herein again.

The following introduces a VNF management entity of the presentembodiments. Referring to FIG. 8 , a VNF management entity 800 in anembodiment is configured to manage a hardware resource, and the VNFmanagement entity 800 in this embodiment includes: a receiving unit 801,configured to acquire an instantiated VNF message, where theinstantiated VNF message includes location information of a hardwareresource that a virtual machine running a VNFC requests to allocate; anda sending unit 802, configured to send a hardware resource allocationrequest message to a VIM according to the instantiated VNF message,where the hardware resource allocation request message is used torequest the VIM to allocate the hardware resource to the virtualmachine, and the hardware resource allocation request message includesthe location information of the hardware resource that the virtualmachine requests to allocate.

In specific implementation, the VNF management entity includes avirtualized network function manager VNFM or a network functionsvirtualization orchestrator (NFVO). When the VNF management entityincludes the VNFM, the receiving unit 801 receives an instantiated VNFmessage sent by an operator or element management (Element Management,EM). When the VNF management entity includes the NFVO, the receivingunit 801 receives an instantiated VNF message sent by an operator or anoperation support system (OSS).

The virtual machine is a virtual machine that runs a VNFC. In additionto the location information of the hardware resource, the instantiatedVNF message may further include information such as an exclusiveidentity or a shared identity, and/or a quantity of CPUs and/or a memorysize and/or a hard disk capacity that the virtual machine requests toallocate.

The location information of the hardware resource may be any one or anycombination of the following: city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity; 1 may be used to indicatethe exclusive identity, and 0 may be used to indicate the sharedidentity; and vice versa. The exclusive identity is used to identifythat the hardware resource, at a specified location, that the virtualmachine requests to allocate is exclusively occupied by the virtualmachine, and the shared identity is used to identify that the hardwareresource, at the specified location, that the virtual machine requeststo allocate may be shared with another virtual machine. When a servicethat runs on the virtual machine is a sensitive service, for securityconsideration, the instantiated VNF message had better carry theexclusive identity.

The sending unit 802 sends a hardware resource allocation requestmessage to a VIM according to the instantiated VNF message received bythe receiving unit 801, so as to request the VIM to allocate thehardware resource to the virtual machine, where the hardware resourceallocation request message includes the location information of thehardware resource that the virtual machine requests to allocate.

In specific implementation, the sending unit 802 may first determine,according to the location information that is of the hardware resourceand included in the instantiated VNF message, a VIM that manages thehardware resource, and then send the hardware resource allocationrequest message to the VIM that manages the hardware resource. Thehardware resource request message may further include other informationincluded in the instantiated VNF message.

In a running process, the VNFC may send a hardware resource adjustmentrequest message to the VNF management entity according to usage of ahardware resource of the VNFC; the receiving unit 801 receives thehardware resource adjustment request message, where the hardwareresource adjustment request message includes location information andadjustment information that are of a hardware resource that the VNFCrequests to adjust, and adjustment information included in the hardwareresource adjustment request message may be information such as memory ordisk expansion and CPU or memory reduction.

The sending unit 802 forwards the hardware resource adjustment requestmessage received by the receiving unit 801 to the VIM, so as to requestthe VIM to adjust the hardware resource at a corresponding location;according to the hardware resource adjustment request message, the VIMmay expand a memory or disk at a specified location, and reduce a CPU ormemory at a specified location.

In this embodiment, after a receiving unit acquires an instantiated VNFmessage, a sending unit may carry, in a hardware resource allocationrequest message, location information that is of a hardware resourcethat a virtual machine running a service requests to allocate andincluded in the instantiated VNF message, and send the hardware resourceallocation request message to a VIM, so as to request the VIM toallocate a hardware resource at a specified location to the virtualmachine according to the hardware resource allocation request message.In this way, for a sensitive service such as lawful interception,location information of a hardware resource related to the sensitiveservice may be clearly known; and according to the location information,sealing of a related physical device may be implemented, aconfidentiality measure is taken to prohibit an unauthorized person fromtouching, operating, and destructing the related physical device, and soon, thereby meeting a requirement of the sensitive service. In addition,the sending unit may further forward, to the VIM, a hardware resourceadjustment request message that is sent by a VNF or a VNFC and receivedby the receiving unit, so as to request the VIM to adjust a hardwareresource at a corresponding location, thereby further meetingrequirements of different services.

In a specific embodiment, the VNF management entity that is configuredto manage a hardware resource may include a receiver and a transmitter,where: the receiver is configured to acquire an instantiated VNFmessage, where the instantiated VNF message includes locationinformation of a hardware resource that a virtual machine running a VNFCrequests to allocate; and the transmitter is configured to send ahardware resource allocation request message to a VIM according to theinstantiated VNF message, where the hardware resource allocation requestmessage is used to request the VIM to allocate the hardware resource tothe virtual machine, and the hardware resource allocation requestmessage includes the location information of the hardware resource thatthe virtual machine requests to allocate.

It should be noted that the VNF management entity in this embodiment mayfurther be configured to implement other functions that can beimplemented by the foregoing VNF management entity that is configured tomanage a hardware resource, and details are not described herein again.

Referring to FIG. 9 , a VNF management entity 900 in an embodiment isconfigured to implement a method for querying a location of a hardwareresource provided in the present embodiments, and the management entity900 in this embodiment includes: a processing unit 901, configured todetermine a virtualized network function (VNF) or VNFC that needs to bequeried, and searches for a virtual machine according to a mappingrelationship, where the virtual machine includes a virtual machine thatruns the VNFC that needs to be queried; a sending unit 902, configuredto send a VM query request to a VIM that manages the virtual machine, soas to request the VIM to query hardware resource information of thevirtual machine, where the VM query request includes a virtual machineidentity or virtual container identity of the virtual machine; and areceiving unit 903, configured to receive the hardware resourceinformation that is of the virtual machine and returned by the VIM,where the hardware resource information includes location information ofthe hardware resource.

In specific implementation, the processing unit 901 may determine,according to a query request sent by an external system, the VNFC thatneeds to be queried, where the query request includes identityinformation of the VNFC that needs to be queried. The external systemmay be a management system of a sensitive service.

The identity information of the VNFC that needs to be queried includes afunctional entity identity of the VNFC (the functional entity identityis information that is used to identify a VNFC and agreed by the VNFmanagement entity and the external system, for example, an internetprotocol (IP) address of a VNFC functional entity) (VNFC entity id), oridentity information of a VNF to which the VNFC belongs (when the VNFhas only one VNFC, the identity information of the VNF to which the VNFCbelongs may be used to identify the VNFC) (the identity information ofthe VNF includes a functional entity identity VNF entity id of the VNFor a VNF identity VNF id), or a VNFC identity (VNFC id), or acombination of identity information of a VNF to which the VNFC belongsand a VNFC identity (VNF id+VNFC id or VNF entity id+VNFC id).

In addition, when the VNF management entity needs to verify relatedinformation of any VNFC, for example, to verify whether a location of ahardware resource of a VNFC is valid, the processing unit 901 determinesthat the VNFC is the VNFC that needs to be queried. The processing unit901 searches for the virtual machine according to the mappingrelationship, and the virtual machine includes a virtual machine thatruns the VNFC that needs to be queried and is determined by theprocessing unit 901.

The mapping relationship includes: a correspondence between a functionalentity identity of each VNFC and the virtual machine identity (VNFCentity id<=>VM id); or a correspondence between identity information ofa VNF to which each VNFC belongs and the virtual machine identity (VNFid<=>VM id or VNF entity id<=>VM id); or a correspondence between a VNFCidentity of each VNFC and the virtual machine identity (VNFC id<=>VMid); or a correspondence between a combination of identity informationof a VNF to which each VNFC belongs and a VNFC identity, and the virtualmachine identity (VNF id+VNFC id<=>VM id or VNF entity id+VNFC id<=>VMid); or a correspondence between a functional entity identity of eachVNFC and the virtual container identity (VNFC entity id<=>VC id); or acorrespondence between identity information of a VNF to which each VNFCbelongs and the virtual container identity (VNF id<=>VC id or VNF entityid<=>VC id); or a correspondence between a VNFC identity of each VNFCand the virtual container identity (VNFC id<=>VC id); or acorrespondence between a combination of identity information of a VNF towhich each VNFC belongs and a VNFC identity, and the virtual containeridentity (VNF id+VNFC id<=>VC id or VNF entity id+VNFC id<=>VC id). Themapping relationship may be dynamically maintained and updated in realtime.

The sending unit 902 sends, according to a search result of theprocessing unit 901, a VM query request to a VIM that manages thevirtual machine, so as to request the VIM to query hardware resourceinformation of the virtual machine. The VM query request includes avirtual machine identity (VM id) or virtual container identity (VC id)of the virtual machine.

The receiving unit 903 receives the hardware resource information thatis of the virtual machine and returned by the VIM, where the hardwareresource information includes location information of the hardwareresource.

The location information of the hardware resource includes any one orany combination of the following: city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity. In addition, the hardwareresource information that is of the virtual machine and returned by theVIM may further include information such as a quantity of CPUs and/or amemory size that are/is allocated to the virtual machine.

In specific implementation, the foregoing VNF management entity includesa virtualized network function manager VNFM or a NFVO.

In this embodiment, a processing unit may search for, according to amapping relationship, a virtual machine that runs a VNF that needs to bequeried or a virtual machine that runs a VNFC; then a sending unit sendsa VM query request to a VIM, so as to request the VIM to query hardwareresource information of the virtual machine; a receiving unit receivesthe hardware resource information of the virtual machine, where thehardware resource information includes location information of ahardware resource. In this way, for a sensitive service such as lawfulinterception, location information of a hardware resource related to thesensitive service may be clearly known; and according to the locationinformation, sealing of a related physical device may be implemented, aconfidentiality measure is taken to prohibit an unauthorized person fromtouching, operating, and destructing the related physical device, and soon, thereby meeting a requirement of the sensitive service.

In a specific embodiment, the VNF management entity that is configuredto query a location of a hardware resource may include a processor and atransceiver, where: the processor is configured to determine a VNFC thatneeds to be queried, and search for, according to a mappingrelationship, a virtual machine that runs the VNFC that needs to bequeried; and the transceiver is configured to: send a VM query requestto a VIM that manages the virtual machine, so as to request the VIM toquery hardware resource information of the virtual machine, where the VMquery request includes a virtual machine identity or virtual containeridentity of the virtual machine; and receive the hardware resourceinformation that is of the virtual machine and returned by the VIM,where the hardware resource information includes location information ofthe hardware resource.

It should be noted that the VNF management entity in this embodiment mayfurther be configured to implement other functions that can beimplemented by the foregoing VNF management entity that is configured toquery a location of a hardware resource, and details are not describedherein again.

Referring to FIG. 10 , a VIM in an embodiment is configured to implementa method for querying a location of a hardware resource provided in thepresent embodiments, and a VIM 1000 in this embodiment includes: areceiving unit 1001, configured to receive a VM query request sent by aVNF management entity, where the VM query request includes a virtualmachine identity or virtual container identity of a virtual machine thatneeds to be queried; a querying unit 1002, configured to query hardwareresource information of the virtual machine according to the VM queryrequest; and a sending unit 1003, configured to send the found hardwareresource information of the virtual machine to the VNF managemententity, where the hardware resource information includes locationinformation of the hardware resource.

In specific implementation, the location information of the hardwareresource includes any one or any combination of the following: cityinformation, equipment room information, cabinet information, a deviceidentity, a port network identity, and a network interface identity.

The hardware resource information that is of the virtual machine andfound by the VIM may further include information such as a quantity ofCPUs and/or a memory size that are/is allocated to the virtual machine.

In this embodiment, after a receiving unit receives a VM query requestsent by a VNF management entity, a querying unit may query hardwareresource information of a virtual machine that runs a VNF or VNFC thatneeds to be queried, and then a sending unit returns found hardwareresource information to the VNF management entity, where the hardwareresource information includes location information of a hardwareresource. In this way, for a sensitive service such as lawfulinterception, location information of a hardware resource related to thesensitive service may be clearly known; and according to the locationinformation, sealing of a related physical device may be implemented, aconfidentiality measure is taken to prohibit an unauthorized person fromtouching, operating, and destructing the related physical device, and soon, thereby meeting a requirement of the sensitive service.

In a specific embodiment, the VIM that is configured to query a locationof a hardware resource may include a transceiver and a processor, where:the transceiver is configured to receive a VM query request sent by aVNF management entity, where the VM query request includes a virtualmachine identity or virtual container identity of a virtual machine thatneeds to be queried; the processor is configured to query hardwareresource information of the virtual machine according to the VM queryrequest; and the transceiver is further configured to send the foundhardware resource information of the virtual machine to the VNFmanagement entity, where the hardware resource information includeslocation information of the hardware resource.

It should be noted that the VIM in this embodiment may further beconfigured to implement other functions that can be implemented by theforegoing VIM that is configured to query a location of a hardwareresource, and details are not described herein again.

In addition, the described apparatus embodiment is merely exemplary. Theunits described as separate parts may or may not be physically separate,and parts displayed as units may or may not be physical units, may belocated in one position, or may be distributed on a plurality of networkunits. Some or all of the modules may be selected according to actualrequirements to achieve the objectives of the solutions of theembodiments. In addition, in the accompanying drawings of the apparatusembodiments provided by the present embodiments, connectionrelationships between modules indicate that the modules havecommunication connections with each other, which may be specificallyimplemented as one or more communications buses or signal cables. Aperson of ordinary skill in the art may understand and implement theembodiments of the present invention without creative efforts.

Based on the foregoing descriptions of the embodiments, a person skilledin the art may clearly understand that the present embodiments may beimplemented by software in addition to necessary universal hardware orby dedicated hardware only, including a dedicated integrated circuit, adedicated CPU, a dedicated memory, a dedicated component and the like.Generally, any functions that can be performed by a computer program canbe easily implemented by using corresponding hardware. Moreover, aspecific hardware structure used to achieve a same function may be ofvarious forms, for example, in a form of an analog circuit, a digitalcircuit, a dedicated circuit, or the like. However, as for the presentembodiments, software program implementation is a better implementationmanner in most cases. Based on such an understanding, the technicalsolutions of the present embodiments essentially or the partcontributing to the prior art may be implemented in a form of a softwareproduct. The software product is stored in a readable storage medium,such as a floppy disk, a universal serial bus (USB) flash drive, aremovable hard disk, a read-only memory (ROM), a random access memory(RAM), a magnetic disk, or an optical disc of a computer, and includesseveral instructions for instructing a computer device (which may be apersonal computer, a server, a network device, and the like) to performthe methods described in the embodiments of the present invention.

The foregoing describes in detail a method for managing a hardwareresource, a method for querying a location of a hardware resource, and arelated apparatus that are provided in the embodiments of the presentinvention. A person of ordinary skill in the art may, based on the ideaof the present embodiments, make modifications with respect to thespecific implementation manners and the application scope. Therefore,the content of this specification shall not be construed as a limitationto the present embodiments.

What is claimed is:
 1. A method in a virtualized network function (VNF)network comprising: receiving an instantiated message sent by anoperation support system (OSS), the instantiated message requesting aVNF to be instantiated, the instantiated message comprises locationinformation of a hardware resource that a virtual machine running theVNF requests to allocate and an exclusive identity, the exclusiveidentity identifying that the hardware resource is exclusively occupiedby the virtual machine; and sending a hardware resource allocationrequest message to a virtualized infrastructure manager (VIM) of the VNFnetwork according to the instantiated message, the hardware resourceallocation request message requesting that the VIM allocate the hardwareresource to the virtual machine, and the hardware resource allocationrequest message comprising the location information of the hardwareresource and the exclusive identity, wherein based on the hardwareresource allocation request message, the hardware resource is allocated,by the VIM, at a corresponding location to the virtual machine accordingto the location information of the hardware resource.
 2. The methodaccording to claim 1, wherein the location information of the hardwareresource comprises at least one of city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity.
 3. The method according toclaim 1, wherein sending the hardware resource allocation requestmessage comprises: determining, according to the location information ofthe hardware resource, a VIM that manages the hardware resource; andsending the hardware resource allocation request message to the VIM thatmanages the hardware resource.
 4. The method according to claim 1,further comprising: receiving a hardware resource adjustment requestmessage sent by the VNF, the hardware resource adjustment requestmessage comprising location information and adjustment information of ahardware resource that the VNF requests to adjust; and forwarding thehardware resource adjustment request message to the VIM, to request thatthe VIM adjust the hardware resource at a corresponding location.
 5. Themethod according to claim 1, wherein the hardware resource includes aCPU, a memory, and a hard drive.
 6. A virtualized network function (VNF)system comprising: a virtualization network functions manager (VNFM)comprising a processor, and a non-transitory computer readable storagemedium storing a program for execution by the processor, the programincluding instructions to receive an instantiated message sent by anoperation support system (OSS), the instantiated message requesting aVNF to be instantiated, the instantiated message comprising locationinformation of a hardware resource that a virtual machine running theVNF requests to allocate and an exclusive identity, the exclusiveidentity identifying that the hardware resource is exclusively occupiedby the virtual machine, and send a hardware resource allocation requestmessage to an virtualized infrastructure manager (VIM) according to theinstantiated message, the hardware resource allocation request messagerequesting that the VIM allocate the hardware resource to the virtualmachine, and the hardware resource allocation request message comprisingthe location information of the hardware resource and the exclusiveidentity; and the VIM, the VIM comprising a processor, and anon-transitory computer readable storage medium storing a program forexecution by the processor, the program including instructions toreceive the hardware resource allocation request message, and allocatethe hardware resource at a corresponding location to the virtual machineaccording to the location information of the hardware resource.
 7. Thesystem according to claim 6, wherein the location information of thehardware resource comprises at least one of city information, equipmentroom information, cabinet information, a device identity, a port networkidentity and a network interface identity.
 8. The system according toclaim 6, wherein the instructions to send a hardware resource allocationrequest message at the VNFM comprises instructions to: determine,according to the location information of the hardware resource, a VIMthat manages the hardware resource; and send the hardware resourceallocation request message to the VIM that manages the hardwareresource.
 9. The system according to claim 6, wherein the program of theVNFM further comprises instructions to: receive a hardware resourceadjustment request message sent by the VNF, wherein the hardwareresource adjustment request message comprises location information andadjustment information of a hardware resource that the VNF requests toadjust; and forward the hardware resource adjustment request message tothe VIM, to request that the VIM adjust the hardware resource at acorresponding location.
 10. The system according to claim 6, wherein thehardware resource includes a CPU, a memory, and a hard drive.
 11. Avirtualization network functions manager (VNFM) of a virtualized networkfunction (VNF) system comprising: a processor, and a non-transitorycomputer readable storage medium storing a program for execution by theprocessor, the program comprising instructions to: receive aninstantiated message sent by an operation support system (OSS), theinstantiated message requesting a VNF to be instantiated, theinstantiated message comprising location information of a hardwareresource that a virtual machine running the VNF requests to allocate andan exclusive identity, the exclusive identity identifying that thehardware resource is exclusively occupied by the virtual machine, andsend a hardware resource allocation request message to an virtualizedinfrastructure manager (VIM) according to the instantiated message, thehardware resource allocation request message requesting that the VIMallocate the hardware resource to the virtual machine, and the hardwareresource allocation request message comprising the location informationof the hardware resource and the exclusive identity.
 12. The VNFMaccording to claim 11, wherein the location information of the hardwareresource comprises at least one of city information, equipment roominformation, cabinet information, a device identity, a port networkidentity and a network interface identity.
 13. The VNFM according toclaim 11, wherein the instructions to send the hardware resourceallocation request message to the VIM comprises instructions to:determine, according to the location information of the hardwareresource, a VIM that manages the hardware resource; and send thehardware resource allocation request message to the VIM that manages thehardware resource.
 14. The VNFM according to claim 11, wherein theprogram comprises further instructions to: receive a hardware resourceadjustment request message sent by the VNF, wherein the hardwareresource adjustment request message comprises location information andadjustment information of a hardware resource that the VNF requests toadjust; and forward the hardware resource adjustment request message tothe VIM, to request that the VIM adjust the hardware resource at acorresponding location.
 15. The VNFM according to claim 11, wherein thehardware resource includes a CPU, a memory, and a hard drive.
 16. Themethod according to claim 1, wherein the instantiated message isreceived by a virtualization network functions manager (VNFM) in the VNFnetwork, and wherein the hardware resource allocation request message issent from the VNFM.
 17. The method according to claim 1, furthercomprising: receiving, by the VIM, the hardware resource allocationrequest message; and allocating, by the VIM, the hardware resource atthe corresponding location to the virtual machine according to thelocation information of the hardware resource.
 18. A method in avirtualized network function (VNF) network comprising: receiving aninstantiated message sent by an operation support system (OSS), theinstantiated message requesting a VNF to be instantiated, theinstantiated message comprises location information of a hardwareresource that a virtual machine running the VNF requests to allocate andan exclusive identity, the exclusive identity identifying that thehardware resource is exclusively occupied by the virtual machine; andsending a hardware resource allocation request message to a virtualizedinfrastructure manager (VIM) of the VNF network according to theinstantiated message, the hardware resource allocation request messagerequesting that the VIM allocate the hardware resource to the virtualmachine, and the hardware resource allocation request message comprisingthe location information of the hardware resource and the exclusiveidentity; receiving the hardware resource allocation request message;and allocating the hardware resource at a corresponding location to thevirtual machine according to the location information of the hardwareresource.
 19. The method according to claim 18, further comprising:receiving a hardware resource adjustment request message sent by theVNF, the hardware resource adjustment request message comprisinglocation information and adjustment information of a hardware resourcethat the VNF requests to adjust; and forwarding the hardware resourceadjustment request message to the VIM, to request that the VIM adjustthe hardware resource at a corresponding location.
 20. The methodaccording to claim 18, wherein the location information of the hardwareresource comprises at least one of city information, equipment roominformation, cabinet information, a device identity, a port networkidentity, and a network interface identity.